package cn.jbooter.mq.autoconfigure.rocketmq.properties;

import org.springframework.boot.context.properties.ConfigurationProperties;

import cn.jbooter.mq.autoconfigure.rocketmq.consts.RocketMQConstants;


/**
 * 自定义rocketmq 配置
 * @author HeJian
 *
 */
@ConfigurationProperties(prefix = "spring.rocketmq")
public class RocketProperties {

	/** 是否开启 **/
	private boolean enabled=false;
	/**name server address**/
	private String namesrvAddr;
	/**发送超时时间(单位:毫秒), 默认3000毫秒**/
	private int sendMsgTimeout=3000;
	/**是否使用vip channel**/
	private boolean vipChannelEnabled = false;
	/** 生产者group id **/
	private String mqProducerGroup = RocketMQConstants._DEFAULT_PRODUCER_GROUP;

	public String getNamesrvAddr() {
		return namesrvAddr;
	}
	public void setNamesrvAddr(String namesrvAddr) {
		this.namesrvAddr = namesrvAddr;
	}
	public int getSendMsgTimeout() {
		return sendMsgTimeout;
	}
	public void setSendMsgTimeout(int sendMsgTimeout) {
		this.sendMsgTimeout = sendMsgTimeout;
	}
	public boolean isVipChannelEnabled() {
		return vipChannelEnabled;
	}
	public void setVipChannelEnabled(boolean vipChannelEnabled) {
		this.vipChannelEnabled = vipChannelEnabled;
	}
	public boolean isEnabled() {
		return enabled;
	}
	public void setEnabled(boolean enabled) {
		this.enabled = enabled;
	}
	public String getMqProducerGroup() {
		return mqProducerGroup;
	}
	public void setMqProducerGroup(String mqProducerGroup) {
		this.mqProducerGroup = mqProducerGroup;
	}
	
}
